package com.ecoolex.cms.system.entity;

import com.ecoolex.framework.common.annotation.Description;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Date;
import org.springframework.lang.NonNull;

/**
 *
 *   Vr 场景<br>
 *<br>
 * 数据表： cms_vr_scene
 *
 */
@Description({"Vr 场景"})
public class VRScene implements Serializable {
    /**
     *
     *   场景Id    <br>
     *<br>
     * 字段名： cms_vr_scene.SceneId
     */
    @Description({"场景Id", "不能为空", "数据长度: 10"})
    @NonNull
    private Integer sceneId;

    /**
     *
     *   开放ID    <br>
     *<br>
     * 字段名： cms_vr_scene.OpenId
     */
    @Description({"开放ID", "不能为空", "数据长度: 200"})
    @NonNull
    private String openId;

    /**
     *
     *   用户Id    <br>
     *<br>
     * 字段名： cms_vr_scene.UserId
     */
    @Description({"用户Id", "不能为空", "数据长度: 10"})
    @NonNull
    private Integer userId;

    /**
     *
     *   场景名称    <br>
     *<br>
     * 字段名： cms_vr_scene.SceneName
     */
    @Description({"场景名称", "不能为空", "数据长度: 50"})
    @NonNull
    private String sceneName;

    /**
     *
     *   场景介绍    <br>
     *<br>
     * 字段名： cms_vr_scene.SceneDescribe
     */
    @Description({"场景介绍", "数据长度: 500"})
    private String sceneDescribe;

    /**
     *
     *   城市Id    <br>
     *<br>
     * 字段名： cms_vr_scene.CityId
     */
    @Description({"城市Id", "数据长度: 10"})
    private Integer cityId;

    /**
     *
     *   详细地址    <br>
     *<br>
     * 字段名： cms_vr_scene.Address
     */
    @Description({"详细地址", "数据长度: 200"})
    private String address;

    /**
     *
     *   Url访问地址    <br>
     *<br>
     * 字段名： cms_vr_scene.Url
     */
    @Description({"Url访问地址", "数据长度: 1024"})
    private String url;

    /**
     *
     *   发布渠道    <br>
     *<br>
     * 字段名： cms_vr_scene.ReleaseChannel
     */
    @Description({"发布渠道", "数据长度: 100"})
    private String releaseChannel;

    /**
     *
     *   状态;1:编辑;2:上线;3:下线;    <br>
     *<br>
     * 字段名： cms_vr_scene.Status
     */
    @Description({"状态;1:编辑;2:上线;3:下线;", "不能为空", "数据长度: 5"})
    @NonNull
    private Integer status;

    public static final Boolean NOT_DELETED = Deleted.NOT_DELETED.value();

    public static final Boolean IS_DELETED = Deleted.IS_DELETED.value();

    /**
     *
     *   逻辑删除    <br>
     *<br>
     * 字段名： cms_vr_scene.Deleted
     */
    @Description({"逻辑删除", "不能为空", "数据长度: 1"})
    @NonNull
    private Boolean deleted;

    /**
     *
     *   创建用户    <br>
     *<br>
     * 字段名： cms_vr_scene.CreateUser
     */
    @Description({"创建用户", "不能为空", "数据长度: 50"})
    @NonNull
    private String createUser;

    /**
     *
     *   创建时间    <br>
     *<br>
     * 字段名： cms_vr_scene.CreateTime
     */
    @Description({"创建时间", "不能为空", "数据长度: 26"})
    @NonNull
    private Date createTime;

    /**
     *
     *   修改用户    <br>
     *<br>
     * 字段名： cms_vr_scene.UpdateUser
     */
    @Description({"修改用户", "不能为空", "数据长度: 50"})
    @NonNull
    private String updateUser;

    /**
     *
     *   修改时间    <br>
     *<br>
     * 字段名： cms_vr_scene.UpdateTime
     */
    @Description({"修改时间", "不能为空", "数据长度: 26"})
    @NonNull
    private Date updateTime;

    private static final long serialVersionUID = 1L;

    /**
     * 获取参数<br><br>
     *
     *   场景Id    <br>
     *<br>
     * 字段名： cms_vr_scene.SceneId
     */
    public Integer getSceneId() {
        return sceneId;
    }

    /**
     * 设置参数<br><br>
     *
     *   场景Id<br>
     *<br>
     * 字段名： cms_vr_scene.SceneId
     */
    public void setSceneId(Integer sceneId) {
        this.sceneId = sceneId;
    }

    /**
     * 获取参数<br><br>
     *
     *   开放ID    <br>
     *<br>
     * 字段名： cms_vr_scene.OpenId
     */
    public String getOpenId() {
        return openId;
    }

    /**
     * 设置参数<br><br>
     *
     *   开放ID<br>
     *<br>
     * 字段名： cms_vr_scene.OpenId
     */
    public void setOpenId(String openId) {
        this.openId = openId == null ? null : openId.trim();
    }

    /**
     * 获取参数<br><br>
     *
     *   用户Id    <br>
     *<br>
     * 字段名： cms_vr_scene.UserId
     */
    public Integer getUserId() {
        return userId;
    }

    /**
     * 设置参数<br><br>
     *
     *   用户Id<br>
     *<br>
     * 字段名： cms_vr_scene.UserId
     */
    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    /**
     * 获取参数<br><br>
     *
     *   场景名称    <br>
     *<br>
     * 字段名： cms_vr_scene.SceneName
     */
    public String getSceneName() {
        return sceneName;
    }

    /**
     * 设置参数<br><br>
     *
     *   场景名称<br>
     *<br>
     * 字段名： cms_vr_scene.SceneName
     */
    public void setSceneName(String sceneName) {
        this.sceneName = sceneName == null ? null : sceneName.trim();
    }

    /**
     * 获取参数<br><br>
     *
     *   场景介绍    <br>
     *<br>
     * 字段名： cms_vr_scene.SceneDescribe
     */
    public String getSceneDescribe() {
        return sceneDescribe;
    }

    /**
     * 设置参数<br><br>
     *
     *   场景介绍<br>
     *<br>
     * 字段名： cms_vr_scene.SceneDescribe
     */
    public void setSceneDescribe(String sceneDescribe) {
        this.sceneDescribe = sceneDescribe == null ? null : sceneDescribe.trim();
    }

    /**
     * 获取参数<br><br>
     *
     *   城市Id    <br>
     *<br>
     * 字段名： cms_vr_scene.CityId
     */
    public Integer getCityId() {
        return cityId;
    }

    /**
     * 设置参数<br><br>
     *
     *   城市Id<br>
     *<br>
     * 字段名： cms_vr_scene.CityId
     */
    public void setCityId(Integer cityId) {
        this.cityId = cityId;
    }

    /**
     * 获取参数<br><br>
     *
     *   详细地址    <br>
     *<br>
     * 字段名： cms_vr_scene.Address
     */
    public String getAddress() {
        return address;
    }

    /**
     * 设置参数<br><br>
     *
     *   详细地址<br>
     *<br>
     * 字段名： cms_vr_scene.Address
     */
    public void setAddress(String address) {
        this.address = address == null ? null : address.trim();
    }

    /**
     * 获取参数<br><br>
     *
     *   Url访问地址    <br>
     *<br>
     * 字段名： cms_vr_scene.Url
     */
    public String getUrl() {
        return url;
    }

    /**
     * 设置参数<br><br>
     *
     *   Url访问地址<br>
     *<br>
     * 字段名： cms_vr_scene.Url
     */
    public void setUrl(String url) {
        this.url = url == null ? null : url.trim();
    }

    /**
     * 获取参数<br><br>
     *
     *   发布渠道    <br>
     *<br>
     * 字段名： cms_vr_scene.ReleaseChannel
     */
    public String getReleaseChannel() {
        return releaseChannel;
    }

    /**
     * 设置参数<br><br>
     *
     *   发布渠道<br>
     *<br>
     * 字段名： cms_vr_scene.ReleaseChannel
     */
    public void setReleaseChannel(String releaseChannel) {
        this.releaseChannel = releaseChannel == null ? null : releaseChannel.trim();
    }

    /**
     * 获取参数<br><br>
     *
     *   状态;1:编辑;2:上线;3:下线;    <br>
     *<br>
     * 字段名： cms_vr_scene.Status
     */
    public Integer getStatus() {
        return status;
    }

    /**
     * 设置参数<br><br>
     *
     *   状态;1:编辑;2:上线;3:下线;<br>
     *<br>
     * 字段名： cms_vr_scene.Status
     */
    public void setStatus(Integer status) {
        this.status = status;
    }

    public void andLogicalDeleted(boolean deleted) {
        setDeleted(deleted ? Deleted.IS_DELETED.value() : Deleted.NOT_DELETED.value());
    }

    /**
     * 获取参数<br><br>
     *
     *   逻辑删除    <br>
     *<br>
     * 字段名： cms_vr_scene.Deleted
     */
    public Boolean getDeleted() {
        return deleted;
    }

    /**
     * 设置参数<br><br>
     *
     *   逻辑删除<br>
     *<br>
     * 字段名： cms_vr_scene.Deleted
     */
    public void setDeleted(Boolean deleted) {
        this.deleted = deleted;
    }

    /**
     * 获取参数<br><br>
     *
     *   创建用户    <br>
     *<br>
     * 字段名： cms_vr_scene.CreateUser
     */
    public String getCreateUser() {
        return createUser;
    }

    /**
     * 设置参数<br><br>
     *
     *   创建用户<br>
     *<br>
     * 字段名： cms_vr_scene.CreateUser
     */
    public void setCreateUser(String createUser) {
        this.createUser = createUser == null ? null : createUser.trim();
    }

    /**
     * 获取参数<br><br>
     *
     *   创建时间    <br>
     *<br>
     * 字段名： cms_vr_scene.CreateTime
     */
    public Date getCreateTime() {
        return createTime;
    }

    /**
     * 设置参数<br><br>
     *
     *   创建时间<br>
     *<br>
     * 字段名： cms_vr_scene.CreateTime
     */
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    /**
     * 获取参数<br><br>
     *
     *   修改用户    <br>
     *<br>
     * 字段名： cms_vr_scene.UpdateUser
     */
    public String getUpdateUser() {
        return updateUser;
    }

    /**
     * 设置参数<br><br>
     *
     *   修改用户<br>
     *<br>
     * 字段名： cms_vr_scene.UpdateUser
     */
    public void setUpdateUser(String updateUser) {
        this.updateUser = updateUser == null ? null : updateUser.trim();
    }

    /**
     * 获取参数<br><br>
     *
     *   修改时间    <br>
     *<br>
     * 字段名： cms_vr_scene.UpdateTime
     */
    public Date getUpdateTime() {
        return updateTime;
    }

    /**
     * 设置参数<br><br>
     *
     *   修改时间<br>
     *<br>
     * 字段名： cms_vr_scene.UpdateTime
     */
    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public enum Deleted {
        NOT_DELETED(new Boolean("false"), "未删除"),
        IS_DELETED(new Boolean("true"), "已删除");

        private final Boolean value;

        private final String name;

        Deleted(Boolean value, String name) {
            this.value = value;
            this.name = name;
        }

        public Boolean getValue() {
            return this.value;
        }

        public Boolean value() {
            return this.value;
        }

        public String getName() {
            return this.name;
        }
    }

    public enum Column {
        sceneId("SceneId", "sceneId", "INTEGER", false),
        openId("OpenId", "openId", "VARCHAR", false),
        userId("UserId", "userId", "INTEGER", false),
        sceneName("SceneName", "sceneName", "VARCHAR", false),
        sceneDescribe("SceneDescribe", "sceneDescribe", "VARCHAR", false),
        cityId("CityId", "cityId", "INTEGER", false),
        address("Address", "address", "VARCHAR", false),
        url("Url", "url", "VARCHAR", false),
        releaseChannel("ReleaseChannel", "releaseChannel", "VARCHAR", false),
        status("Status", "status", "INTEGER", false),
        deleted("Deleted", "deleted", "BIT", false),
        createUser("CreateUser", "createUser", "VARCHAR", false),
        createTime("CreateTime", "createTime", "TIMESTAMP", false),
        updateUser("UpdateUser", "updateUser", "VARCHAR", false),
        updateTime("UpdateTime", "updateTime", "TIMESTAMP", false);

        private static final String BEGINNING_DELIMITER = "\"";

        private static final String ENDING_DELIMITER = "\"";

        private final String column;

        private final boolean isColumnNameDelimited;

        private final String javaProperty;

        private final String jdbcType;

        public String value() {
            return this.column;
        }

        public String getValue() {
            return this.column;
        }

        public String getJavaProperty() {
            return this.javaProperty;
        }

        public String getJdbcType() {
            return this.jdbcType;
        }

        Column(String column, String javaProperty, String jdbcType, boolean isColumnNameDelimited) {
            this.column = column;
            this.javaProperty = javaProperty;
            this.jdbcType = jdbcType;
            this.isColumnNameDelimited = isColumnNameDelimited;
        }

        public String desc() {
            return this.getEscapedColumnName() + " DESC";
        }

        public String asc() {
            return this.getEscapedColumnName() + " ASC";
        }

        public static Column[] excludes(Column ... excludes) {
            ArrayList<Column> columns = new ArrayList<>(Arrays.asList(Column.values()));
            if (excludes != null && excludes.length > 0) {
                columns.removeAll(new ArrayList<>(Arrays.asList(excludes)));
            }
            return columns.toArray(new Column[]{});
        }

        public String getEscapedColumnName() {
            if (this.isColumnNameDelimited) {
                return new StringBuilder().append(BEGINNING_DELIMITER).append(this.column).append(ENDING_DELIMITER).toString();
            } else {
                return this.column;
            }
        }
    }
}